<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>用户接口</title>
<script src="https://cdnjs.cloudflare.com/ajax/libs/prettify/r298/prettify.min.js"></script>
<link href="https://cdnjs.cloudflare.com/ajax/libs/prettify/r298/prettify.min.css" rel="stylesheet">
<link href="../style.css" rel="stylesheet" />
</head>
<body onload="PR.prettyPrint()">
<div id="wmd-preview" class="wmd-preview">
<h1><a href="../index.html">《首页</a> 用户接口:</h1>
<div class="toc">
    <ul>
    <li><a href="#关注用户">关注用户</a></li><li><a href="#用户列表">用户列表</a></li><li><a href="#用户信息">用户信息</a></li><li><a href="#收藏图书">收藏图书</a></li><li><a href="#保存用户">保存用户</a></li><li><a href="#获取用户列表2">获取用户列表2</a></li><li><a href="#获取用户列表[无类型信息]">获取用户列表[无类型信息]</a></li><li><a href="#消息列表">消息列表</a></li>
    </ul>
</div>
<hr>
<h2 id="关注用户">关注用户</h2>

<pre class="prettyprint lang-json">
method：POST
url: /api/v1/u/follow
</pre>

<p><strong>参数列表</strong></p>

<table><tr><th>参数名</th><th>类型</th><th>必需</th><th>描述</th></tr><tr><td>pictures</td><td>string[]</td><td>false</td><td>照片</td></tr><tr><td>model.name</td><td>string</td><td>false</td><td>名字</td></tr><tr><td>model.password</td><td>string</td><td>false</td><td>密码</td></tr></table>

<p>返回结果: <a href="../javaCodes/controller_UserController_follow_UserVO.html">Android Code</a> | <a href="../iosCodes/controller_UserController_follow_UserVO.html">IOS Code</a></p>

<pre class="prettyprint lang-json">
{
  "userId": "string //用户id",
  "userName": "string //用户名",
  "friends": [
    {
      "userId": "string //用户id",
      "userName": "string //用户名"
    }
  ],
  "readBooks": [
    {
      "bookId": "long //图书id",
      "bookName": "string //图书名称"
    }
  ],
  "isFollow": "boolean //是否关注"
}
</pre>

<hr><h2 id="用户列表">用户列表</h2>

<pre class="prettyprint lang-json">
method：GET, OPTIONS
url: /api/v1/u/list
</pre>

<p><strong>参数列表</strong></p>

<table><tr><th>参数名</th><th>类型</th><th>必需</th><th>描述</th></tr><tr><td>page</td><td>int</td><td>true</td><td>页数</td></tr><tr><td>pageSize</td><td>int</td><td>false</td><td>每页条数</td></tr></table>

<p>返回结果: <a href="../javaCodes/controller_UserController_list_UserVO.html">Android Code</a> | <a href="../iosCodes/controller_UserController_list_UserVO.html">IOS Code</a></p>

<pre class="prettyprint lang-json">
[
  {
    "userId": "string //用户id",
    "userName": "string //用户名",
    "friends": [
      {
        "userId": "string //用户id",
        "userName": "string //用户名"
      }
    ],
    "readBooks": [
      {
        "bookId": "long //图书id",
        "bookName": "string //图书名称"
      }
    ],
    "isFollow": "boolean //是否关注"
  }
]
</pre>

<hr><h2 id="用户信息">用户信息</h2>

<pre class="prettyprint lang-json">
method：GET
url: /api/v1/u/info
</pre>

<p><strong>参数列表</strong></p>

<table><tr><th>参数名</th><th>类型</th><th>必需</th><th>描述</th></tr><tr><td>userId</td><td>string</td><td>true</td><td>用户id</td></tr></table>

<p>返回结果: <a href="../javaCodes/controller_UserController_userInfo_UserVO.html">Android Code</a> | <a href="../iosCodes/controller_UserController_userInfo_UserVO.html">IOS Code</a></p>

<pre class="prettyprint lang-json">
{
  "userId": "string //用户id",
  "userName": "string //用户名",
  "friends": [
    {
      "userId": "string //用户id",
      "userName": "string //用户名"
    }
  ],
  "readBooks": [
    {
      "bookId": "long //图书id",
      "bookName": "string //图书名称"
    }
  ],
  "isFollow": "boolean //是否关注"
}
</pre>

<hr><h2 id="收藏图书">收藏图书</h2>

<pre class="prettyprint lang-json">
method：POST
url: /api/v1/u/favorite
</pre>

<p><strong>参数列表</strong></p>

<table><tr><th>参数名</th><th>类型</th><th>必需</th><th>描述</th></tr><tr><td>bookId</td><td>string</td><td>true</td><td>图书id</td></tr></table>

<p>返回结果: <a href="../javaCodes/controller_UserController_favoriteBook_BookDetailVO.html">Android Code</a> | <a href="../iosCodes/controller_UserController_favoriteBook_BookDetailVO.html">IOS Code</a></p>

<pre class="prettyprint lang-json">
{
  "bookId": "long //图书id",
  "bookName": "string //图书名称",
  "storeCount": "int //馆藏数量",
  "pictures": "string[] //图片",
  "owner": {
    "userId": "string //用户id",
    "userName": "string //用户名",
    "friends": [
      {
        "userId": "string //用户id",
        "userName": "string //用户名"
      }
    ],
    "readBooks": [
      {
        "bookId": "long //图书id",
        "bookName": "string //图书名称"
      }
    ],
    "isFollow": "boolean //是否关注"
  }
}
</pre>

<hr><h2 id="保存用户">保存用户</h2>

<pre class="prettyprint lang-json">
method：POST
url: /api/v1/u/saveUser
</pre>

<p><strong>参数列表</strong></p>

<pre class="prettyprint lang-json">
{
  "pictures": "string[] //照片",
  "model": {
    "name": "string //名字"
  }
}
</pre>

<p>返回结果: <a href="../javaCodes/controller_UserController_saveUser_BookDetailVO.html">Android Code</a> | <a href="../iosCodes/controller_UserController_saveUser_BookDetailVO.html">IOS Code</a></p>

<pre class="prettyprint lang-json">
{
  "bookId": "long //图书id",
  "bookName": "string //图书名称",
  "storeCount": "int //馆藏数量",
  "pictures": "string[] //图片",
  "owner": {
    "userId": "string //用户id",
    "userName": "string //用户名",
    "friends": [
      {
        "userId": "string //用户id",
        "userName": "string //用户名"
      }
    ],
    "readBooks": [
      {
        "bookId": "long //图书id",
        "bookName": "string //图书名称"
      }
    ],
    "isFollow": "boolean //是否关注"
  }
}
</pre>

<hr><h2 id="获取用户列表2">获取用户列表2</h2>

<pre class="prettyprint lang-json">
method：POST
url: /api/v1/u/list-new
</pre>

<p><strong>参数列表</strong></p>

<table><tr><th>参数名</th><th>类型</th><th>必需</th><th>描述</th></tr><tr><td>page</td><td>int</td><td>false</td><td>页数</td></tr></table>

<p>返回结果: <a href="../javaCodes/controller_UserController_getUserList_Result.html">Android Code</a> | <a href="../iosCodes/controller_UserController_getUserList_Result.html">IOS Code</a></p>

<pre class="prettyprint lang-json">
{
  "message": "string //消息",
  "list": [
    {
      "userId": "string //用户id",
      "userName": "string //用户名",
      "friends": [
        {
          "userId": "string //用户id",
          "userName": "string //用户名"
        }
      ],
      "readBooks": [
        {
          "bookId": "long //图书id",
          "bookName": "string //图书名称"
        }
      ],
      "isFollow": "boolean //是否关注"
    }
  ]
}
</pre>

<hr><h2 id="获取用户列表[无类型信息]">获取用户列表[无类型信息]</h2>

<pre class="prettyprint lang-json">
method：POST
url: /api/v1/u/list-new-notype
</pre>

<p><strong>参数列表</strong></p>

<table><tr><th>参数名</th><th>类型</th><th>必需</th><th>描述</th></tr><tr><td>page</td><td>int</td><td>false</td><td>页数</td></tr></table>

<p>返回结果: <a href="../javaCodes/controller_UserController_getUserList3_Result.html">Android Code</a> | <a href="../iosCodes/controller_UserController_getUserList3_Result.html">IOS Code</a></p>

<pre class="prettyprint lang-json">
{
  "message": {},
  "list": []
}
</pre>

<hr><h2 id="消息列表">消息列表</h2>

<pre class="prettyprint lang-json">
method：POST
url: /api/v1/u/message-list
</pre>

<p><strong>参数列表</strong></p>

<table><tr><th>参数名</th><th>类型</th><th>必需</th><th>描述</th></tr></table>

<p>返回结果: <a href="#">Android Code</a> | <a href="#">IOS Code</a></p>

<pre class="prettyprint lang-json">
string[]
</pre>

<hr>
</div>
</body>
</html>